let vm=new Vue({
    el:'#main',
    data:{
        service:{}
    },
    methods:{
        close:function () {
            let index = parent.layer.getFrameIndex(window.name); //获取窗口索引
            parent.layer.close(index);//通过父窗口layer对象关闭子窗口
        }
    },
    created:function () {
        this.service=parent.layer.service
    }
})